﻿
Namespace LightSwitchApplication

    Public Class CurrentPayrollDeductions

        Private Sub Amount_Validate(results As EntityValidationResultsBuilder)
            ' results.AddPropertyError("<Error-Message>")
            If Amount <= 0 Then
                results.AddPropertyError("Amount should not be less than or equal to 0.")
            End If
        End Sub


        Private Sub StartDate_Validate(results As EntityValidationResultsBuilder)
            ' results.AddPropertyError("<Error-Message>")
            If StartDate > EndDate Then
                results.AddPropertyError("Start date should be earlier than end date.")
            End If
        End Sub
    End Class

End Namespace
